package ${package};

import com.sttram.plume.bill.core.dao.impl.BaseDaoImpl;
import com.sttram.plume.bill.intf.dao.I${tableClass.shortClassName}Dao;
import ${tableClass.fullClassName}Entity;
import org.springframework.stereotype.Repository;

import java.util.List;

<#assign dateTime = .now>
/**
*
*
* @since ${dateTime?string["yyyy-MM-dd HH:mm:ss"]}
*/

@Repository
public class ${tableClass.shortClassName}${mapperSuffix} extends BaseDaoImpl implements I${tableClass.shortClassName}Dao {


    @Override
    public ${tableClass.shortClassName}Entity selectById(Integer id) {
        return this.findObjById("${tableClass.shortClassName}EntityMapper.selectByPrimaryKey", id, ${tableClass.shortClassName}Entity.class);
    }

    @Override
    public List<${tableClass.shortClassName}Entity> selectList(${tableClass.shortClassName}Entity entity) {
        return this.findListByParameter("${tableClass.shortClassName}EntityMapper.selectList", entity, ${tableClass.shortClassName}Entity.class);
    }

    @Override
    public void insertSelective(${tableClass.shortClassName}Entity entity) {
        this.save("${tableClass.shortClassName}EntityMapper.insertSelective", entity);
    }

    @Override
    public int updateBillById(${tableClass.shortClassName}Entity entity) {
        return this.update("${tableClass.shortClassName}EntityMapper.updateByPrimaryKey", entity);
    }

}
